﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Xml.Serialization;
using System.IO;
using System.Xml;
using Wix.Aura.Common.CustomTypes;
using System.Xml.Schema;

namespace Wix.Aura.Common {

	[XmlRootAttribute("Wix", Namespace = "http://schemas.microsoft.com/Wix/2006/wi")]
	public class WixProject : Serializable {

		private WixProject() { }

		public WixProject(Product product) {
			Product = product;
		}

		public Product Product { get; set; }
		[XmlAttribute]
		public VersionType? RequiredVersion { get; set; }

		public override XmlSchema GetSchema() {
			return null;
		}

		public override void ReadXml(XmlReader reader) {
			throw new NotImplementedException();
		}

		public override void WriteXml(XmlWriter writer) {
			writer.WriteAttribute("requiredversion", RequiredVersion);
			Product.WriteXml(writer);
		}
	}
}
